<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
    <title>文章管理</title>
 <link rel="stylesheet" type="text/css" href="<?php echo base_url().'public/admin';?>/css/hdui.css">
    <link rel="stylesheet" type="text/css" href="<?php echo base_url().'public/admin';?>/css/bootstrap.min.css">
    <style type="text/css">
        .tcdPageCode{
            text-align: center;
        }
        .tcdPageCode a:hover, .tcdPageCode .current, .tcdPageCode02 a:hover, .tcdPageCode02 .current {
            color: #fff;
            border-color: #4FE8E5;
            background: #4FE8E5;
        }

        .tcdPageCode a, .tcdPageCode span, .tcdPageCode02 a, .tcdPageCode02 span {
            margin-left: 2px;
            margin-right: 2px;
            padding: 2px 7px;
            color: #a0a0a0;
            border: 1px #a0a0a0 solid;

            transition: color .2s linear, border-color .2s linear, background .2s linear;
            -moz-transition: color .2s linear, border-color .2s linear, background .2s linear;
            -ms-transition: color .2s linear, border-color .2s linear, background .2s linear;
            -o-transition: color .2s linear, border-color .2s linear, background .2s linear;
            -webkit-transition: color .2s linear, border-color .2s linear, background .2s linear;
        }
    </style>
</head>
<body>
<div class="wrap">
    <table class="table2">
        <thead>
        <tr>
            <td>id</td>
            <td>问题</td>
            <td>A</td>
            <td>B</td>
            <td>C</td>
            <td>D</td>

            <td width="150">操作</td>
        </tr>
        </thead>

        <?php foreach($question as $v):?>
        <tbody>
            <tr>
                <td><?php echo $v['id'];?></td>
            <td><?php echo $v['title'];?></td>

                <?php if($v['correct']==='A'):?>
                <td style="color:red;"><?php echo $v['A'];?></td>
                <?php else:?>
                <td><?php echo $v['A'];?></td>
                <?php endif;?>

                <?php if($v['correct']==='B'):?>
                <td style="color:red;"><?php echo $v['B'];?></td>
                <?php else:?>
                <td><?php echo $v['B'];?></td>
                <?php endif;?>

                <?php if($v['correct']==='C'):?>
                <td style="color:red;"><?php echo $v['C'];?></td>
                <?php else:?>
                <td><?php echo $v['C'];?></td>
                <?php endif;?>

                <?php if($v['correct']==='D'):?>
                <td style="color:red;"><?php echo $v['D'];?></td>
                <?php else:?>
                <td><?php echo $v['D'];?></td>
                <?php endif;?>
            <td width="150">
            	 <a href="<?php echo site_url('/admin/Ask/edit/'.$v['id'])?>"><button type="button" class="btn btn-primary btn-sm">修改</button></a>
                <a href="javascript:;" onclick="if(confirm('确定删除吗?'))
                location.href='<?php echo site_url('/admin/Ask/del/'.$v['id'])?>' "><button type="button" class="btn btn-danger btn-sm">删除</button></a>
            </td>

        </tr>
        </tbody>
        <?php endforeach;?>
    </table>
    <div class="tcdPageCode">
        <?php echo $links?>
    </div>
</div>

</body>
</html>


